-- GENERATED SPELL FOR [Fel Reaver Sentinel] --


function spell0_21949(pUnit, Event) --@FRS Quest Credit,n/a--
pUnit:FullCastSpellOnTarget(38022,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_21949', 563, 1)
end

function spell1_21949(pUnit, Event) --@Sonic Boom,n/a--
pUnit:FullCastSpellOnTarget(38052,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_21949', 3250, 1)
end

function spell2_21949(pUnit, Event) --@World Breaker,n/a--
pUnit:FullCastSpellOnTarget(38006,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_21949', 4326, 1)
end

function Sorts_21949(pUnit, Event)
local choix_sorts_21949 = math.random(0, 2)
if choix_sorts_21949 == 0 then
pUnit:RegisterEvent('spell0_21949', 1, 1)
end
if choix_sorts_21949 == 1 then
pUnit:RegisterEvent('spell1_21949', 1, 1)
end
if choix_sorts_21949 == 2 then
pUnit:RegisterEvent('spell2_21949', 1, 1)
end
end

function mob21949_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_21949', math.random(1500, 3000), 1)
end

function mob21949_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob21949_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob21949_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(21949, 1, 'mob21949_Action')
RegisterUnitEvent(21949, 2, 'mob21949_Leave')
RegisterUnitEvent(21949, 3, 'mob21949_Kill')
RegisterUnitEvent(21949, 4, 'mob21949_Die')
